﻿<Window x:Class="Sigma.DrBlue.WpfUI.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:converter="clr-namespace:Sigma.DrBlue.WpfUI.Converters"
        Title="MainWindow" Height="350" Width="525" Loaded="Window_Loaded">
    <Window.Resources>
        <ResourceDictionary>
            <converter:ResourceValueConverter x:Key="resourceValueConverter"/>
        </ResourceDictionary>
    </Window.Resources>
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>
            <RowDefinition Height="*"/>
            <RowDefinition Height="Auto"/>
        </Grid.RowDefinitions>
        
        <StackPanel Orientation="Horizontal">
            <ComboBox Width="200"/>
            <Button Content="Add" Command="{Binding ParseCommand}"></Button>
            <Button Content="Add Folder" Command="{Binding AddFolderCommand}"></Button>
            
            <Button x:Name="btnOptions" Click="btnOptions_Click" Content="Options" />
        </StackPanel>
        
        <DataGrid Grid.Row="1" AutoGenerateColumns="False" IsReadOnly="True" GridLinesVisibility="Vertical" ItemsSource="{Binding StringResources,Mode=OneWay}">
            <DataGrid.Columns>
                <DataGridTextColumn Binding="{Binding Key,Mode=OneWay}" Header="Key"/>
                <DataGridTextColumn Binding="{Binding Mode=OneWay, Path=Values, Converter={StaticResource resourceValueConverter}, ConverterParameter=en}" Header="en" CanUserSort="False"/>
                <DataGridTextColumn Binding="{Binding Mode=OneWay, Path=Values, Converter={StaticResource resourceValueConverter}, ConverterParameter=de}" Header="de" CanUserSort="False"/>
                <DataGridTextColumn Binding="{Binding Mode=OneWay, Path=Values, Converter={StaticResource resourceValueConverter}, ConverterParameter=zh-CHS}" Header="zh-CHS" CanUserSort="False"/>
            </DataGrid.Columns>
        </DataGrid>
    </Grid>
</Window>
